package com.rambo.baselib.model.weather;

import java.util.Date;
import java.util.List;

/***********************************************************************
 * <p>@description:
 * <p>@author: rambo
 * <p>@version: 1.0.0
 * <p>@created on: 2022/1/18 13:52
 **********************************************************************/
public class WeatherApiResult {
    String code;
    //当前API的最近更新时间
    Date updateTime;
    List<WarnWeather> warning;
    List<DayWeather> daily;
    Weather now;

    String msg;
    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public List<WarnWeather> getWarning() {
        return warning;
    }

    public void setWarning(List<WarnWeather> warning) {
        this.warning = warning;
    }

    public List<DayWeather> getDaily() {
        return daily;
    }

    public void setDaily(List<DayWeather> daily) {
        this.daily = daily;
    }

    public Weather getNow() {
        return now;
    }

    public void setNow(Weather now) {
        this.now = now;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
    public boolean success(){
        return code!=null&&code.equals("200");
    }
}
